/*
 * MCameraGUI.h
 *
 *  Created on: Mar 23, 2013
 *      Author: ohnozzy
 */

#ifndef MCAMERAGUI_H_
#define MCAMERAGUI_H_
#include <ompl/geometric/PathGeometric.h>
#include <fcl/math/transform.h>
#include <fcl/shape/geometric_shapes.h>
#include "flyingcamera/base/VehiclePath.h"
#include "flyingcamera/gui/CameraGUI.h"

namespace flyingcamera
{
   namespace gui{
      namespace moving{
          class MCameraGUI : public flyingcamera::gui::CameraGUI {
           protected:
            std::vector<fcl::Box> moving_obstacle;
            std::vector<const flyingcamera::base::VehiclePath*> obstacle_path;
            std::vector<fcl::Vec3f> moving_obstacle_color;
           public:
            MCameraGUI(const ompl::geometric::PathGeometric& p, const flyingcamera::base::VehiclePath* pc, double d): flyingcamera::gui::CameraGUI(p, pc, d){}
            void addMObstacle(const fcl::Box& b, const flyingcamera::base::VehiclePath* path, const fcl::Vec3f& c){
        	  obstacle_path.push_back(path);
        	  moving_obstacle.push_back(b);
        	  moving_obstacle_color.push_back(c);
            }
            std::size_t getMObstacleCount() const {
              return moving_obstacle.size();
            }
            virtual bool hasMovingObstacle() const {return true;}
            void getMObstacle(unsigned i, double t, fcl::Box& b, fcl::Transform3f& tf, fcl::Vec3f& c) const;
          };
        }

   }
}


#endif /* MCAMERAGUI_H_ */
